jQuery(document).ready(function($) {
    //获取当前的路径
   function getCurrentUri(){
        return window.location.pathname;
   }
   //根据路径选择对应项
   var uri = getCurrentUri();
   var target = $("a[href='"+uri+"']");
   $(target).addClass('active');
   $(target)
    .parents('.collapse')
    .prev("a[data-toggle='collapse']")
    .click()

});
